//预警类型
enum MsgType {
  code10006104(['10006104']),
  code10004(['10004100', '10004102']),
  code10007(['10007100', '10007102']),
  code10004103(['10004103']),
  code220(['220']),
  code10005(['10005101', '10005102']),
  code10005100(['10005100']),
  code10007101(['10007101']),
  code10005103(['10005103', '10006100', '10006101', '10006102', '10006103']),
  code10004101(['10004101']),
  code10003(['10003']);

  final List<String> code;
  const MsgType(this.code);
  factory MsgType.fromCode(String code) {
    return values.firstWhere((element) => element.code.contains(code));
  }
}
